package com.company;

import java.util.InputMismatchException;
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
	// write your code here
       //method();
        //捕获异常
       //method1();
       // method2();
        //抛出异常
        try {
            method4();
        }catch (Exception e){
            System.out.println("执行出错");
        }

    }
    public static void method(){
        int a =new Scanner(System.in).nextInt();
         int b=new Scanner(System.in).nextInt();
         System.out.println(a/(double)b);
    }
    public static void method1(){
        try {
            int a =new Scanner(System.in).nextInt();
            int b=new Scanner(System.in).nextInt();
            System.out.println(a/(double)b);
        }catch (InputMismatchException a){
            System.out.println("输入只能是数字");
            System.out.println("输入不能为小数");
          System.out.println("第二次输入不能为0");
        }catch (Exception a){
            System.out.println("清输入正确的数字");
        }
    }
    public static void method2(){
        try {
            int a =new Scanner(System.in).nextInt();
        int b=new Scanner(System.in).nextInt();
        System.out.println(a/(double)b);
    }catch (Exception a){
            System.out.println("输入的不对");
        }
    }
    public static void method4()throws Exception{
        int a =new Scanner(System.in).nextInt();
        int b=new Scanner(System.in).nextInt();
        System.out.println(a/(double)b);
    }
}
